package freedom.easyit.domain;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.Id;

import freedom.easyit.enums.GenderEnum;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 通讯录
 * 
 * @author Charlie Email:tingfangcao@163.com
 * @date 2020/10/21
 */
@Entity
@Data
@NoArgsConstructor
@AllArgsConstructor
public class ContactBook {
    @Id
    @Column(length = 128, nullable = false, unique = true)
    private String email;//电子邮箱
    
    @Column(length = 64, nullable = false)
    private String name;//姓名

    @Column(nullable = false)
    private Date hiredate;//入职日期
    
    @Column(nullable = false)
    private Date birthday;//生日

    @Enumerated(EnumType.STRING)
    @Column(length = 64, nullable = false)
    private GenderEnum gender;//性别
    
}
